package com.example.demo.controller;

import com.demo.persistent.StudentController;
import com.example.demo.bean.Student;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user")
public class UserController {

    private StudentController studentController = new StudentController();

    @RequestMapping("/getStudent")
    @ResponseBody
    public Student getStudent() {
        return studentController.getStudent();
    }
}
